// 对象数据实现迭代
Object.prototype[Symbol.iterator] = function () {
  const itor = Object.values(this);
  return itor[Symbol.iterator]();
  // yield* Object.values(this);
};

const ob = {
  realName: "zhangsan",
  age: 18,
  height: "180cm",
};

const [realName, age, height] = ob;
console.log(realName, age, height);

for (const value of ob) {
  console.log(value);
}
